package com.yzd.otherlearn.jvm;

import com.yzd.otherlearn.util.Print;

public class LoadClassTest5 {
	
	static class DeadLoopClass {
		static {
			if(true) {
				Print.print(Thread.currentThread() + " init DeadLoopClass");
				while(true) {}
			}
		}
	}
	public static void main(String[] args) {
		Runnable script = new Runnable() {
			
			@Override
			public void run() {
				Print.print(Thread.currentThread() + " start");
				DeadLoopClass dcl = new DeadLoopClass();
				Print.print(Thread.currentThread() + " run over");
			}
		};
		
		Thread t1 = new Thread(script);
		Thread t2 = new Thread(script);
		t1.start();
		t2.start();
	}
}
